package com.atguigui.leetcode1;

/**
 * 2446.判断两个事件是否存在冲突
 * Project: leetcode
 * Package: com.atguigui.leetcode1
 * Version: 1.0
 * <p>
 * Created by WJX on 2023/5/17 11:28
 */
public class P2446DetermineIfTwoEventsHaveConflict {
    public static void main(String[] args) {
        Solution solution = new P2446DetermineIfTwoEventsHaveConflict().new Solution();
        // TO TEST
    }

    //leetcode submit region begin(Prohibit modification and deletion)
    class Solution {
        public boolean haveConflict(String[] event1, String[] event2) {
            return Integer.parseInt(event1[1].replace(":", "")) >= Integer.parseInt(event2[0].replace(":", "")) ||
                    Integer.parseInt(event1[0].replace(":", "")) <= Integer.parseInt(event2[1].replace(":", ""));
        }
    }
}
